import { createApp } from 'vue';
// import './style.css';
import App from './App.vue';
import ElementPlus from 'element-plus';         //引入element-plus脚本
import 'element-plus/dist/index.css';           //引入element-plus样式
import router from './router';
import MyComponent from './components/MyComponent.vue'
import { createPinia } from 'pinia';
const pinia=createPinia();
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate';
pinia.use(piniaPluginPersistedstate);
import './mocks/index';


const app = createApp(App);
app.use(ElementPlus); // 注册ElementPlus
app.use(router);      // 注册路由
app.use(pinia);
app.component('my-component',MyComponent);    //将组件注册为全局可用
app.mount('#app');    // 挂载到DOM